package com.ruoyi.pay.domain.from;

import javax.validation.constraints.*;

public class CreateOrderForm {
    //订单号
    @NotEmpty(message = "订单号不能为空")
    @Size(max = 30)
    private String orderNum;
    //单位 分
    @NotNull(message = "订单金额必传")
    @Min(value = 1,message = "金额最少一分钱")
    private Long orderPrice;
    //支付方式 默认：微信
    private String payWay = "WX";
    //商品信息，多个请用逗号分割
    @Size(max = 255)
    private String orderGoods;
    //订单类型 默认1：商品类型
    private String orderType = "1";
    //签名->加密方法 md5(order_id + order_price + secretkey) // 这里的 + 是字符串拼接
    @NotEmpty(message = "签名不能为空")
    private String sign;
    //回调地址
    private String redirectUrl;
    //扩展信息
    @Size(max = 50,message = "扩展字段最大不能超过50个字符")
    private String extension;

    public String getPayWay() {
        return payWay;
    }

    public void setPayWay(String payWay) {
        this.payWay = payWay;
    }

    public String getOrderGoods() {
        return orderGoods;
    }

    public void setOrderGoods(String orderGoods) {
        this.orderGoods = orderGoods;
    }

    public String getOrderType() {
        return orderType;
    }

    public void setOrderType(String orderType) {
        this.orderType = orderType;
    }

    public String getSign() {
        return sign;
    }

    public void setSign(String sign) {
        this.sign = sign;
    }

    public String getRedirectUrl() {
        return redirectUrl;
    }

    public void setRedirectUrl(String redirectUrl) {
        this.redirectUrl = redirectUrl;
    }

    public String getExtension() {
        return extension;
    }

    public void setExtension(String extension) {
        this.extension = extension;
    }

    public String getOrderNum() {
        return orderNum;
    }

    public void setOrderNum(String orderNum) {
        this.orderNum = orderNum;
    }

    public long getOrderPrice() {
        return orderPrice;
    }

    public void setOrderPrice(long orderPrice) {
        this.orderPrice = orderPrice;
    }
}
